package com.atde._05_behavioral_design_patterns.state.app;


/**
 * @BelongsProject: hsp_java_design_mode
 * @BelongsPackage: com.atde._05_behavioral_design_patterns.state.app
 * @Author: Del
 * @CreateTime: 2025-06-30  11:34
 * @Description: 状态模式 --- 具体的状态类 --- 表示当前为发放奖品完毕状态
 * 说明：当我们 activity 改变成 DispenseOutState 状态时，说明已经发放奖品完毕，不能再进行其他操作了
 * @Version: 1.0
 */
public class DispenseOutState extends State{
    // 持有活动引用
    RaffleActivity activity;

    public DispenseOutState(RaffleActivity activity) {
        this.activity = activity;
    }

    @Override
    void deductMoney() {
        System.out.println("奖品发送完毕，请下次再参加");
    }

    @Override
    boolean raffle() {
        System.out.println("奖品发送完毕，请下次再参加");
        return false;
    }

    @Override
    void dispensePrize() {
        System.out.println("奖品发送完毕，请下次再参加");
    }
}
